

import 'package:isar_community/isar.dart';

part 'function_table.g.dart';

///功能表    todo:同时添加part function_table 每次修改属性名都要重新 dart run build_runner build  生成dart 文件
@collection
class FunctionTableModel {
  Id? id;

  /// mac地址
  @Index(unique: true, replace: true)
  String? mac;

  /// 创建的Utc时间戳
  int? createUtcTimestamp;

  LocalFunctionTableModel? localFunctionTableModel;

  bool? syncFunctionTable;

  bool? syncBasicInitializationState;

  @override
  String toString() {
    return 'FunctionTableModel{id: $id, mac: $mac, createUtcTimestamp: $createUtcTimestamp,syncBasicInitializationState: $syncBasicInitializationState, localFunctionTableModel: $localFunctionTableModel, syncFunctionTable: $syncFunctionTable}';
  }
}

@embedded
class LocalFunctionTableModel {
  /// 1勿扰
  bool? disturb;

  /// 2喝水提醒
  bool? waterRemind;

  /// 3站立提醒
  bool? standingRemind;

  /// 4女性健康
  bool? femaleHealth;

  /// 5天气
  bool? weather;

  /// 6消息提醒
  bool? messageData;

  /// 7是否bt协议通话
  bool? btCall;

  /// 8是否ble协议通话
  bool? bleCall;

  /// 9日程提醒
  bool? scheduleRemind;

  /// 10语音助手
  bool? voiceAssistant;

  /// 11快捷卡片
  bool? quickCard;

  /// 12世界时钟
  bool? worldTime;

  /// 13常用联系人
  bool? frequentContacts;

  /// 14gps功能
  bool? gps;

  /// 15在线星历
  bool? onlineGnss;

  /// 16离线星历
  bool? offlineGnss;

  ///17紧急联系人(SOS)
  bool? emergencyContacts;

  /// hrv 18
  bool? hrv;

  ///19 按键快捷操作
  bool? buttonCrown;

  ///消息通知里面的消息详情
  bool? isShowMessageDetails;

  ///20 专注模式
  bool? focusMode;

  ///21 寻找手表
  bool? findWatch;

  ///22 支持Alexa
  bool? alexa;

  ///23 应用列表
  bool? appList;

  ///24 数据埋点
  bool? eventTracking;

  ///应用试图
  bool? appView;

  ///快捷回复  28
  bool? quickReply;

  ///strava
  bool? strava;

  ///是否支持消息应用名下发  bit1
  bool? isSHowAppName;

  ///是否支持其他应用开关  bit2
  bool? isShowOtherAPP;

  ///是否支持生理周期提醒开关menstruation_reminder_switch
  bool? isMenstruationReminderSwitch;

  ///女性健康开关状态
  bool? menstrualPeriodSetSwitch;

  ///26//运动处方
  bool? sportPrescription;

  ///运动识别;// 27
  bool? sportRecognition;

  ///appIcon、应用名
  bool? msgAppidDownload;

// // ;// 32;//早安问候 废弃这个字段(因为固件一早就初始值为true了)
//    bool? goodMorningIsSupport;

  ///喝水助手
  bool? waterAssistantIsSupport;

  ///来电提醒
  bool? bleCallComingIsSupport;

  ///是否不支持血氧功能
  bool? spo2NoIsSupport;

  /// 39是否不支持电话本功能,默认是支持
  bool? phonebookNonSupport;

  ///40 传感器开关
  bool? watchSensorsIsSupport;

  ///41音乐文件是否支持发送
  bool? musicFileIsSupportSport;

  ///42 手表方向
  bool? watchDirectionIsSupportSport;

  ///46 早安问候语自定义
  bool? goodMorningContentIsSupport;

  /// 47 是否不支持闹钟
  bool? alarmIsNotSupport;

  /// 48 是否不支持屏幕
  bool? screenBrightnessNotSupport;

  /// 49 是否不支持音乐控制
  bool? musicControlIsNotSupport;

  /// 50 是否不支持表盘
  bool? dialPlateNotSupport;

  /// 51 日程 main_id:0x37
  bool? calendarNotSupport;

  /// 52 健康快照 main_id:0x38
  bool? healthSnapNotSupport;

  /// 53 手势
  bool? gestureIsSupport;

  /// 54 戒指点击测量 main_id:0x36
  bool? ringClickMeasureIsSupport;

  /// 55 app支持发起运动
  bool? appStartSportIsSupport;

  //app支持geobin轨迹数据
  bool? geobinIsSupport;

  ///= 57;//运动课程
  bool? workoutCourseIsSupport;

  ///= 58;//用户头像下载
  bool? userIconIsSupport;

  ///59;//体温
  bool? bodyTemperatureIsSupport;

  /// 60;//戒指提醒开关功能表 main_id:0x36 sub_id:0x04
  bool?  remindSwitchIsSupport;
  ///= 61;//是否支持充电仓
  bool?  battCaseInfoIsSupport;
  /// 是否支持 有氧适能
  bool? cardioFitnessIsSupport;
  //是否支持训练负荷
  bool? trainingLoadIsSupport;

  @override
  String toString() {
    return 'LocalFunctionTableModel{disturb: $disturb, waterRemind: $waterRemind, standingRemind: $standingRemind, femaleHealth: $femaleHealth, weather: $weather, messageData: $messageData, btCall: $btCall, bleCall: $bleCall, scheduleRemind: $scheduleRemind, voiceAssistant: $voiceAssistant, quickCard: $quickCard, worldTime: $worldTime, frequentContacts: $frequentContacts, gps: $gps, onlineGnss: $onlineGnss, offlineGnss: $offlineGnss, emergencyContacts: $emergencyContacts, hrv: $hrv, buttonCrown: $buttonCrown, isShowMessageDetails: $isShowMessageDetails, focusMode: $focusMode, findWatch: $findWatch, alexa: $alexa, appList: $appList, eventTracking: $eventTracking, appView: $appView, quickReply: $quickReply, strava: $strava, isSHowAppName: $isSHowAppName, isShowOtherAPP: $isShowOtherAPP, isMenstruationReminderSwitch: $isMenstruationReminderSwitch, menstrualPeriodSetSwitch: $menstrualPeriodSetSwitch, sportPrescription: $sportPrescription, sportRecognition: $sportRecognition, msgAppidDownload: $msgAppidDownload, waterAssistantIsSupport: $waterAssistantIsSupport, bleCallComingIsSupport: $bleCallComingIsSupport, spo2NoIsSupport: $spo2NoIsSupport, phonebookNonSupport: $phonebookNonSupport, watchSensorsIsSupport: $watchSensorsIsSupport, musicFileIsSupportSport: $musicFileIsSupportSport, watchDirectionIsSupportSport: $watchDirectionIsSupportSport, goodMorningContentIsSupport: $goodMorningContentIsSupport, alarmIsNotSupport: $alarmIsNotSupport, screenBrightnessNotSupport: $screenBrightnessNotSupport, musicControlIsNotSupport: $musicControlIsNotSupport, dialPlateNotSupport: $dialPlateNotSupport, calendarNotSupport: $calendarNotSupport, healthSnapNotSupport: $healthSnapNotSupport, gestureIsSupport: $gestureIsSupport, ringClickMeasureIsSupport: $ringClickMeasureIsSupport, appStartSportIsSupport: $appStartSportIsSupport, geobinIsSupport: $geobinIsSupport, workoutCourseIsSupport: $workoutCourseIsSupport, userIconIsSupport: $userIconIsSupport, bodyTemperatureIsSupport: $bodyTemperatureIsSupport, remindSwitchIsSupport: $remindSwitchIsSupport, battCaseInfoIsSupport: $battCaseInfoIsSupport}';
  }
}
